package com.car.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.car.dao.UserMapper;
import com.car.entity.User;
import com.car.entity.UserExample;
import com.car.service.UserMapperService;

@Service("userService")
public class UserMapperServiceImp implements UserMapperService {

	@Autowired
	private UserMapper userMapper;
	
	@Override
	public User Login(UserExample example) {
		List<User> list = userMapper.selectByExample(example);
		if(list.size()>0){
			return list.get(0);
		}
		return null;
	}

}
